package com.smarttourism.controller;

import com.smarttourism.common.core.domain.R;
import com.smarttourism.domain.Hotelbrand;
import com.smarttourism.domain.Hotelstart;
import com.smarttourism.service.HotelbrandService;
import com.smarttourism.service.HotelstartService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @Author：王祖威
 * @Date ：2024/10/23 19:05
 */
@RestController
@RequestMapping("/hotelstart")
public class HotelstartController {
    @Autowired
    private HotelstartService hotelstartService;

    @GetMapping("/list")
    @PreAuthorize("@ss.hasPermi('hotel:hotel:list')")
    public R findAll(){
        List<Hotelstart> list = hotelstartService.findAll();
        return list != null?R.ok(list):R.fail("查询失败");
    }



}
